<?php

defined('_SECURITY_TOKEN') or die("caia fora");

class modelquery extends model
{
	
	function __construct(  )
	{
		
		
		
	}
	
	public function getQuery( $query ){
				
		$result=false;
		
		try{
				 		
			$db = application::getDb( configuration::db_type);
	// 		
			$db->setParameters(configuration::db_server, 
								configuration::db_port, 
								configuration::db_username, 
								configuration::db_password,
								configuration::db_name);
	
			$query = urldecode($query);
			
			$result = $db->getQuery($query);
			

		}
	    catch (AppException $e) {
	    	throw new AppException( $e->getMessage() );
	    }
		
		return $result;
		
	}



	
}